(global["webpackJsonp"] = global["webpackJsonp"] || []).push([
  ["pages/find/send"], {
    2423: function(t, e, n) {
      "use strict";
      (function(t) {
        Object.defineProperty(e, "__esModule", {
          value: !0
        }), e.default = void 0;
        var i = r(n("a34a")),
          a = n("2f62");

        function r(t) {
          return t && t.__esModule ? t : {
            default: t
          }
        }

        function o(t, e, n, i, a, r, o) {
          try {
            var s = t[r](o),
              c = s.value
          } catch (u) {
            return void n(u)
          }
          s.done ? e(c) : Promise.resolve(c).then(i, a)
        }

        function s(t) {
          return function() {
            var e = this,
              n = arguments;
            return new Promise((function(i, a) {
              var r = t.apply(e, n);

              function s(t) {
                o(r, i, a, s, c, "next", t)
              }

              function c(t) {
                o(r, i, a, s, c, "throw", t)
              }
              s(void 0)
            }))
          }
        }

        function c(t, e) {
          var n = Object.keys(t);
          if (Object.getOwnPropertySymbols) {
            var i = Object.getOwnPropertySymbols(t);
            e && (i = i.filter((function(e) {
              return Object.getOwnPropertyDescriptor(t, e).enumerable
            }))), n.push.apply(n, i)
          }
          return n
        }

        function u(t) {
          for (var e = 1; e < arguments.length; e++) {
            var n = null != arguments[e] ? arguments[e] : {};
            e % 2 ? c(Object(n), !0).forEach((function(e) {
              l(t, e, n[e])
            })) : Object.getOwnPropertyDescriptors ? Object.defineProperties(t, Object.getOwnPropertyDescriptors(n)) : c(Object(n)).forEach((function(e) {
              Object.defineProperty(t, e, Object.getOwnPropertyDescriptor(n, e))
            }))
          }
          return t
        }

        function l(t, e, n) {
          return e in t ? Object.defineProperty(t, e, {
            value: n,
            enumerable: !0,
            configurable: !0,
            writable: !0
          }) : t[e] = n, t
        }
        var f = [
            ["camera"],
            ["album"],
            ["camera", "album"]
          ],
          d = [
            ["compressed"],
            ["original"],
            ["compressed", "original"]
          ],
          h = {
            data: function() {
              return {
                imgPathid: "",
                sendContent: "",
                isshow: !0,
                typearr: ["请选择类别", "日记", "发帖", "问答"],
                cateArr: [],
                cateAll: [],
                cindex: 0,
                index: 0,
                jg: "",
                imageList: [],
                imageLength: 9,
                sourceTypeIndex: 2,
                sizeTypeIndex: 2,
                wanlsys: this.$wanlshop.wanlsys(),
                modalName: null,
                listTouchStart: 0,
                listTouchDirection: null
              }
            },
            computed: u({}, (0, a.mapState)(["chat", "statistics"])),
            onLoad: function() {
              this.getLabel()
            },
            methods: u(u({}, (0, a.mapActions)({
              del: "chat/del",
              empty: "chat/empty"
            })), {}, {
              ListTouchStart: function(t) {
                this.listTouchStart = t.touches[0].pageX
              },
              ListTouchMove: function(t) {
                this.listTouchDirection = t.touches[0].pageX - this.listTouchStart > 0 ? "right" : "left"
              },
              ListTouchEnd: function(t) {
                "left" == this.listTouchDirection ? this.modalName = t.currentTarget.dataset.target : this.modalName = null, this.listTouchDirection = null
              },
              getLabel: function() {
                var t = this;
                return s(i.default.mark((function e() {
                  return i.default.wrap((function(e) {
                    while (1) switch (e.prev = e.next) {
                      case 0:
                        t.$api.get({
                          url: "/wanlshop/find/getLabel",
                          data: {},
                          success: function(e) {
                            t.cateAll = e
                          }
                        });
                      case 1:
                      case "end":
                        return e.stop()
                    }
                  }), e)
                })))()
              },
              openshow: function() {
                this.isshow = !this.isshow
              },
              radioChange: function(t) {
                console.log("radio发生change事件，携带value值为：", t.detail.value)
              },
              bindPickerChange: function(t) {
                this.index = t.target.value, this.jg = this.typearr[this.index], console.log("籍贯为：", this.jg)
              },
              chooseImage: function() {
                var e = s(i.default.mark((function e() {
                  var n = this;
                  return i.default.wrap((function(e) {
                    while (1) switch (e.prev = e.next) {
                      case 0:
                        t.chooseImage({
                          sourceType: f[this.sourceTypeIndex],
                          sizeType: d[this.sizeTypeIndex],
                          count: this.imageLength - this.imageList.length,
                          success: function(t) {
                            n.imageList = n.imageList.concat(t.tempFilePaths)
                          }
                        });
                      case 1:
                      case "end":
                        return e.stop()
                    }
                  }), e, this)
                })));

                function n() {
                  return e.apply(this, arguments)
                }
                return n
              }(),
              previewImage: function(e) {
                var n = e.target.dataset.src;
                t.previewImage({
                  current: n,
                  urls: this.imageList
                })
              },
              deleteImage: function(t) {
                var e = t.target.dataset.index,
                  n = this,
                  i = n.imageList;
                i.splice(e, 1), n.imageList = i
              },
              delthis: function(t) {
                this.cateArr.splice(t, 1)
              },
              addthis: function(t) {
                var e = this.cateArr.indexOf(t);
                e < 0 && this.cateArr.push(t)
              },
              uploadImg: function() {
                for (var e = this, n = e.imgPathid, i = e.imageList.map((function(t, e) {
                    return {
                      name: "images" + e,
                      uri: t
                    }
                  })), a = this.$api.config.baseUrl + "/index/uploadfindImgblob?imgid=" + n, r = i.length, o = 0; o < r; o++) {
                  var s = i[o]["uri"];
                  t.uploadFile({
                    url: a,
                    filePath: s,
                    name: "file",
                    formData: {
                      billGID: "11111111",
                      token: "33333333"
                    },
                    success: function(t) {

                    },
                    fail: function(t) {
                      return !1
                    }
                  })
                }
              },
              sendinfo: function() {
                var e = 0;
                try {
                  var n = t.getStorageSync("userid");
                  n && (e = n)
                } catch (u) {

                }
                if (0 == e) return t.showToast({
                  title: "请先进行登录",
                  duration: 1e3,
                  icon: "none"
                }), void setTimeout((function() {
                  t.navigateTo({
                    url: "/pages/user/auth/auth"
                  })
                }), 2e3);
                var i = this;
                i.imgPathid = e + "_" + (new Date).getTime();
                var a = this.sendContent;
                if ("" != a) {
                  var r = this.cateArr,
                    o = a.substring(0, 16),
                    s = "",
                    c = "";
                  r.forEach((function(t, e) {
                    s += t.id + ",", c += t.name + ","
                  })), s = s.substring(0, s.length - 1), c = c.substring(0, c.length - 1), i.uploadImg(), t.showToast({
                    title: "正在发布...",
                    duration: 3e3,
                    icon: "none"
                  }), setTimeout((function() {
                    i.$api.post({
                      url: "/wanlshop/find/saveRj",
                      skipInterceptorResponse: !0,
                      data: {
                        uid: e,
                        title: o,
                        content: a,
                        isOpen: 0,
                        cids: s,
                        oid: 0,
                        hid: 0,
                        did: 0,
                        sdate: "",
                        sendtype: "activity",
                        cnames: c,
                        imgid: i.imgPathid
                      },
                      success: function(e) {


                        if (e == 1) {
                          t.showToast({
                            title: "发布成功",
                            duration: 2e3,
                            icon: "none"
                          }), t.switchTab({
                            url: "/pages/find/find"
                          })
                        } else {
                          t.showToast({
                            title: e,
                            duration: 2e3,
                            icon: "none"
                          })
                        }


                      }
                    })
                  }), 2e3)
                } else t.showToast({
                  title: "请输入问题内容",
                  duration: 1e3,
                  icon: "none"
                })
              }
            })
          };
        e.default = h
      }).call(this, n("543d")["default"])
    },
    "24f0": function(t, e, n) {
      "use strict";
      n.r(e);
      var i = n("2423"),
        a = n.n(i);
      for (var r in i) "default" !== r && function(t) {
        n.d(e, t, (function() {
          return i[t]
        }))
      }(r);
      e["default"] = a.a
    },
    "3af6": function(t, e, n) {
      "use strict";
      var i;
      n.d(e, "b", (function() {
        return a
      })), n.d(e, "c", (function() {
        return r
      })), n.d(e, "a", (function() {
        return i
      }));
      var a = function() {
          var t = this,
            e = t.$createElement;
          t._self._c
        },
        r = []
    },
    4892: function(t, e, n) {
      "use strict";
      n.r(e);
      var i = n("3af6"),
        a = n("24f0");
      for (var r in a) "default" !== r && function(t) {
        n.d(e, t, (function() {
          return a[t]
        }))
      }(r);
      n("4de5");
      var o, s = n("f0c5"),
        c = Object(s["a"])(a["default"], i["b"], i["c"], !1, null, null, null, !1, i["a"], o);
      e["default"] = c.exports
    },
    "4de5": function(t, e, n) {
      "use strict";
      var i = n("cb55"),
        a = n.n(i);
      a.a
    },
    c129: function(t, e, n) {
      "use strict";
      (function(t) {
        n("77a0");
        i(n("66fd"));
        var e = i(n("4892"));

        function i(t) {
          return t && t.__esModule ? t : {
            default: t
          }
        }
        t(e.default)
      }).call(this, n("543d")["createPage"])
    },
    cb55: function(t, e, n) {}
  },
  [
    ["c129", "common/runtime", "common/vendor"]
  ]
]);
